package top.azusall.securitydemo.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import top.azusall.model.pojo.Role;
import top.azusall.model.pojo.User;
import top.azusall.model.pojo.UserRole;

import java.util.List;

/**
 * @author houmo
 */
@Mapper
public interface UserRoleMapper extends BaseMapper<UserRole> {


    /**
     * 获取用户对应的角色
     *
     * @param userId
     * @return
     */
    List<Role> getRolesByUserId(@Param("userId") Long userId);
}
